package com.zh.elec.dao.impl;

import java.util.List;

import com.zh.elec.dao.SellRecordDao;
import com.zh.elec.dao.base.BaseDao;
import com.zh.elec.model.SellRecord;

/**
 *  销售表
 * @author scy
 *
 */
public class SellRecordDaoImpl extends BaseDao implements SellRecordDao {

	@Override
	public Object save(SellRecord obj) {
		return this.saveOrUpdate(obj);
	}

	@Override
	public Object update(SellRecord obj) {
		return this.saveOrUpdate(obj);
	}

	@Override
	public Object getObjById(SellRecord obj) {
		return this.getObjById(obj);
	}

	@Override
	public Object del(SellRecord obj) {
		return this.del(obj);
	}

	@SuppressWarnings("unchecked")
	@Override
	public List<SellRecord> findByHql(String hql) {
		return this.find(hql);
	}

	@Override
	public List<SellRecord> findByName(String name, Object value) {
		return this.findByName(name, value);
	}

	@Override
	public List<SellRecord> findAll() {
		return this.findByHql(" from SellRecord ");
	}

}
